package com.jicheng.Utils;

/**
 * @ClassName: JudgeSystem
 * @Description: TODO 判断window和Linux
 * @author: khz
 * @date: 2020年09月15日 12:00
 */
public class JudgeSystem {
    public static boolean isLinux() {
        return System.getProperty("os.name").toLowerCase().contains("linux");
    }

    public static boolean isWindows() {
        return System.getProperty("os.name").toLowerCase().contains("windows");
    }

    public  String JudgeSystem() {
        if (isLinux()) {
            return "linux";
        } else if (isWindows()) {
            return "windows";
        } else {
            return "other system";
        }
    }
}
